import 'package:flutter/material.dart';
import 'package:flutter/services.dart';

class SystemChannelPage extends StatefulWidget {
  const SystemChannelPage({super.key});

  @override
  State<SystemChannelPage> createState() => _SystemChannelPageState();
}

class _SystemChannelPageState extends State<SystemChannelPage> {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      body: Column(children: [
        ElevatedButton(
          onPressed: () {
            String content = "TestClipboardData1231";
            print("123");
            Clipboard.setData(ClipboardData(text: content));
          },
          child: const Text("Clipboard.setData"),
        ),
        const TextField(),
      ]),
    );
  }
}
